<!DOCTYPE html>
<html lang='en'>
<head>
    <meta charset='UTF-8'>
    <meta name='viewport' content='width=device-width, initial-scale=1.0'>
    <title>Document</title>
    <script type='text/javascript' src='js/vue.js'></script>
</head>
<body>
    <div id='app'>
        {{msg }}

        <p>{{msg | aa("第一次学") }}</p>
        <p>{{msg | bb()}}</p>
    </div>
    <script type='text/javascript'>

        // Vue.filter("aa",function(str,qqq){
        //     return   str.replace("Hello","Hi"+qqq)
        // })

        var vm = new Vue({
            el: '#app',
            data: {
                msg: 'Hello Vue'
            },
            filters:{
                aa(str,qqq){
                    return   str.replace("Hello","Hi"+qqq)
                },
                bb(str){
                    return  str.replace("Vue","world")
                }
            }
        });
    </script>
</body>
</html>